﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/jui.Master" Inherits="System.Web.Mvc.ViewPage<Dictionary<string, object>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    人员
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div id="layout" class="noNavTab ">
        <div id="navTab">
            <h2 class="contentTitle">
                人员</h2>
            <div class="pageContent">
                <div class="pageFormContent nowrap" layouth="56">
                    <%
                        int id = Utils.StrToInt(ViewData["id"], 0);
                        string tname = "Sys_IBUsers";
                        string url = "/sysManage/list_4";
                        Dictionary<string, object> d = CommonBLL.GetModel(tname, "*", id);
                        if (d != null)
                        {
                            using (Html.BeginEditForm(Database.Default, tname, id, url))
                            { %>
                    
                <dl>
                    <dt>人员名称：</dt>
                    <dd>
                        <%:Html.TextBox("t0_RealName", d["RealName"].ToString(), new { @class = "required textInput", maxlength = "15" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>英文名：</dt>
                    <dd>
                        <%:Html.TextBox("t0_EnName", d["EnName"].ToString(), new { @class = " textInput", maxlength = "50" })%>
                    </dd>
                    <dt>拼音：</dt>
                    <dd>
                        <%:Html.TextBox("t0_spell", d["spell"].ToString(), new { @class = "required textInput", maxlength = "25" })%>
                    </dd>
                    <dt>首字母：</dt>
                    <dd>
                        <%:Html.TextBox("t0_letter", d["letter"].ToString(), new { @class = " textInput", maxlength = "10" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>性别：</dt>
                    <dd>
                        <label>
                        <%:Html.RadioButton("t0_Sex", "男", d["Sex"].ToString() == "男")%>男
                        </label>
                        <label><%:Html.RadioButton("t0_Sex", "女", d["Sex"].ToString() == "女")%>女</label>
                    </dd>
                </dl>
                <dl>
                    <dt>所属机构：</dt>
                    <dd>
                        <select class="combox " name="t0_Company">
                                <%Html.RenderPartial("~/Views/Shared/selectControl.ascx", sysManageBLL.get_fCompany()); %>
                        </select>
                    </dd>
                </dl>
                <dl>
                    <dt>人员照片：</dt>
                    <dd>
                        <a class="button" href="#" id="A1"><span>上传图片</span></a>
                        <div id="hdImg1" class="showImgUrl">
                        <%
                                string imgUrl = d["Imgurl"].ToString().Replace("-p", "");
                                if (!string.IsNullOrEmpty(imgUrl))
                            { %>
                                <span><img src='/<%:imgUrl %>'><a href="?" class="delImg" to="t0_logo">删除</a></span>
                            <%}
                                    %>
                            </div>
                            <%:Html.Hidden("t0_Imgurl", imgUrl, new { @class = " textInput" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>人员编码：</dt>
                    <dd>
                        <%:Html.TextBox("t0_UserCode", d["UserCode"].ToString(), new { @class = "required textInput", maxlength = "25" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>职位名称：</dt>
                    <dd>
                        <%:Html.TextBox("t0_JobTitle", d["JobTitle"].ToString(), new { @class = "required textInput", maxlength = "15" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>户籍：</dt>
                    <dd>
                        <%:Html.TextBox("t0_household", d["household"].ToString(), new { @class = "required textInput", maxlength = "50" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>身份证号：</dt>
                    <dd>
                        <%:Html.TextBox("t0_IdCard", d["IdCard"].ToString(), new { @class = "required textInput", maxlength = "15" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>手机：</dt>
                    <dd>
                        <%:Html.TextBox("t0_MOV", d["MOV"].ToString(), new { @class = "required textInput", maxlength = "15" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>部门电话：</dt>
                    <dd>区号-号码-分机号</dd>
                    <dd>
                        <%:Html.TextBox("t0_TelArea", d["TelArea"].ToString(), new { @class = "digits  textInput", maxlength = "25" })%>
                        <%:Html.TextBox("t0_Tel", d["Tel"].ToString(), new { @class = " textInput", maxlength = "50" })%>
                        <%:Html.TextBox("t0_TelExt", d["TelExt"].ToString(), new { @class = "digits  textInput", maxlength = "25" })%>
                    </dd>
                </dl>
                
                <dl>
                    <dt>部门传真：</dt>
                    <dd>区号-号码-分机号</dd>
                    <dd>
                        <%:Html.TextBox("t0_FaxArea", d["FaxArea"].ToString(), new { @class = "digits  textInput", maxlength = "25" })%>
                        <%:Html.TextBox("t0_Fax", d["Fax"].ToString(), new { @class = " textInput", maxlength = "50" })%>
                        <%:Html.TextBox("t0_FaxExt", d["FaxExt"].ToString(), new { @class = "digits  textInput", maxlength = "25" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>电子邮件：</dt>
                    <dd>
                        <%:Html.TextBox("t0_Email", d["Email"].ToString(), new { @class = " textInput", size = 50, maxlength = "15" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>状态：</dt>
                    <dd>
                        <label>
                        <%:Html.RadioButton("t0_state", "1", d["state"].ToString().Trim()=="1")%>在职
                        </label>
                        <label><%:Html.RadioButton("t0_state", "0", d["state"].ToString().Trim() == "0")%>离职</label>
                    </dd>
                </dl>
                <dl>
                    <dt>QQ号码：</dt>
                    <dd>
                        <%:Html.TextBox("t0_QQ", d["QQ"].ToString(), new { @class = " textInput", size = 50, maxlength = "15" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>MSN：</dt>
                    <dd>
                        <%:Html.TextBox("t0_MSN", d["MSN"].ToString(), new { @class = " textInput", size = 50, maxlength = "15" })%>
                    </dd>
                </dl>
                <dl>
                    <dt>入职日期：</dt>
                    <dd>
                        <%
                                string DatesEmployed = "";
                                if (!string.IsNullOrEmpty(d["DatesEmployed"].ToString()))
                                {
                                    DatesEmployed = Convert.ToDateTime(d["DatesEmployed"]).ToString("yyyy-MM-dd");
                                }
                                 %>
                        <input type="text" name="t0_DatesEmployed" value='<%:DatesEmployed %>' class="date required" readonly="readonly" />
                        <a class="inputDateButton" href="javascript:;">选择</a>
                    </dd>
                </dl>
                <dl>
                    <dt>员工生日：</dt>
                    <dd>
                        <%
                                string DateBirth = "";
                                if (!string.IsNullOrEmpty(d["DateBirth"].ToString()))
                                {
                                     DateBirth = Convert.ToDateTime(d["DateBirth"]).ToString("yyyy-MM-dd");
                                }
                                 %>
                        <input type="text" name="t0_DateBirth" value='<%:DateBirth %>' class="date required" readonly="readonly" />
                        <a class="inputDateButton" href="javascript:;">选择</a>
                    </dd>
                </dl>
                <dl>
                    <dt>备注信息：</dt>
                    <dd>
                        <%:Html.TextArea("t0_remarks", d["remarks"].ToString(), new { rows = "5", cols = "40", maxlength = "500" })%>
                    </dd>
                </dl>
                    <dl>
                        <dt>&nbsp</dt>
                        <dd>
                            <div class="buttonActive">
                                <div class="buttonContent">
                                    <button type="submit">
                                        修改</button></div>
                            </div>
                        </dd>
                        <dd>
                            <a class="button" href='<%:url %>'><span>返回</span></a></dd>
                    </dl>
                    <%}
                        }%>
                </div>
            </div>
        </div>
    </div>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="HeadContent" runat="server">
    <link href="../../content/jui-normal.css" rel="stylesheet" type="text/css" />
    <link href="/content/colorbox.css" rel="stylesheet" type="text/css" />
    <script src="/scripts/jquery.colorbox.js" type="text/javascript"></script>
    <script type="text/javascript" src="/scripts/jquery.autocomplete.min.js"></script>
    <script src="../../../Scripts/common.js" type="text/javascript"></script>
    <script type="text/javascript">
        $(function () {
            createUpload('btnUpload', 't0_logo', 'Dest_Img_Max_1', function () { showUploadImg($('#t0_logo'), $('#hdImg1'), '') });
        });
    </script>
</asp:Content>
